from django.conf.urls import patterns, url
from defapp import views
from django.contrib import admin
admin.autodiscover()

urlpatterns = patterns('',
    url(r'^$', views.get_homepage),
    url(r'^authors/(?P<author_name>\w+)/$', views.get_author),
    url(r'^authors/all', views.get_authors_list),
    url(r'^favorites/', views.get_favorites),
    # url(r'^admin/doc/', include('django.contrib.admindocs.urls')),
    # url(r'^admin/', include(admin.site.urls)),
    url(r'^(?P<type>\w+)/(?P<author>\w+)/(?P<title>\w+)/$', views.get_material),
    url(r'^(?P<type>\w+)/(?P<author>\w+)/$', views.get_materials_list),
    url(r'^(?P<type>\w+)/$', views.get_materials_list),
)

